<?php
namespace App\Http\Controllers\Admin;
use App\http\Controllers\Controller;
use Illuminate\Support\Facades\DB;

class IndexController extends BaseController{
    public function index(){
        $islogin = $this->islogin();
        if (!$islogin) {
            return redirect("/admin/login");
        }
        return view("admin/index");
        
        //视图文件是 resources/views/admin/index.blade.php
    }
    public function welcome() {
        $islogin = $this->islogin();
        if (!$islogin) {
            return redirect("/admin/login");
        }
        return view('admin/welcome');
    }
}